//ownKeys 返回一个由目标对象自身(不包含继承)的属性组成的数组

let obj = {
    a:1,
    b:2,
    [Symbol('key')]:3
}
//[ 'a', 'b', Symbol(key) ]
console.log(Reflect.ownKeys(obj))
console.log(Object.keys(obj))//[a,b]
console.log(Object.getOwnPropertySymbols(obj))//[Symbol('key')]

//has 检查 一个对象是否拥有指定的属性
let obj2 = {
    a:1
}
console.log(obj2.hasOwnProperty('a'))
console.log(Reflect.has(obj2,'a'))
console.log('a' in obj2)

let obj3 = {
    a:1
}
Object.defineProperty(obj3,'b',{value:2})
Reflect.set(obj3,'b',2);
Reflect.set(obj3,'c',3)
console.log(obj3)

console.log(Reflect.get(obj3,'b'))
console.log(Reflect.get(obj3,'c'))


//delete obj.a;
console.log(obj3.a)
Reflect.deleteProperty(obj3,'a')
console.log(obj3.a)